# $Id: PKGBUILD 86496 2013-03-18 11:55:36Z spupykin $
# Maintainer: Sergej Pupykin <pupykin.s+arch@gmail.com>
# Contributor: Andreas Schönfelder <passtschu at freenet dot de>

pkgname=phoronix-test-suite
pkgver=4.4.1
pkgrel=1
pkgdesc="The most comprehensive testing and benchmarking platform available for Linux"
arch=('any')
license=('GPL3')
url="http://www.phoronix-test-suite.com/"
depends=('php')
optdepends=('php-gtk'
	    'php-gd'
	    'php-curl')
install=${pkgname}.install
source=(http://www.phoronix.net/downloads/phoronix-test-suite/releases/phoronix-test-suite-$pkgver.tar.gz)
md5sums=('54e98f06483bcb4f900f7813154b9f3a')

package() {
  cd $srcdir/phoronix-test-suite
  sed -i 's#-packages.sh#-packages.sh --asdeps#' pts-core/objects/client/pts_external_dependencies.php
  install -d $pkgdir/usr/bin $pkgdir/usr/share/phoronix-test-suite
  sed -e "s/^export PTS_DIR=.*/export PTS_DIR=\/usr\/share\/phoronix-test-suite/g" -i phoronix-test-suite
  install -m755 phoronix-test-suite $pkgdir/usr/bin/
  rm -f $pkgdir/usr/share/phoronix-test-suite/pts/etc/scripts/package-build-*
  cp -r pts-core/ $pkgdir/usr/share/phoronix-test-suite/
}
